package com.wry.im;

import com.wry.im.server.ChatNettyServer;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import javax.annotation.Resource;

/**
 * <h1> im服务端启动器 </h1>
 *
 * @author wry
 * @since 2023.04.25
 */
@SpringBootApplication
public class NettyServerApplication implements CommandLineRunner {

    public static void main(String[] args) {
        SpringApplication.run(NettyServerApplication.class, args);
    }

    @Resource
    private ChatNettyServer chatNettyServer;

    @Override
    public void run(String... args) throws Exception {
        chatNettyServer.start();
    }
}
